-
Notifications
You must be signed in to change notification settings - Fork 143
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Machinery to fix total issuance accounting and keep it fixed #595
Conversation
comment tx fee handler Update pallets/subtensor/src/lib.rs Co-authored-by: Cameron Fairchild <cameron@opentensor.ai>
Co-authored-by: Cameron Fairchild <cameron@opentensor.ai>
fd27e9d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we have a test for the total issuance fees hook? If not, that would be great to add.
It will be tested every pr with live state in the existing try-runtime tests |
b34c052
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also add tests for the migrations ?
DO NOT MERGE UNTIL CONST HAS APPROVED |
initialise total issuance with a migration
DO NOT MERGE UNTIL CONST HAS APPROVED
Machinery for #563
pallet_subtensor::TotalIssuance
TotalSubnetLocked
to track the total amount of tokens locked for subnet registrationTotalSubnetLocked
and then rejig the total issuance to be the sum of issued tokens, staked tokens, and tokens locked for subnet registrationset_subnet_locked_balance
to updateTotalSubnetLocked
to reflect changes inSubnetLocked
on_nonzero_unbalanced
handler for transaction fees, which will remove the burnt transaction fee amount frompallet_subtensor::TotalIssuance
before finally dropping ittry-state
checks forTotalStake
TotalSubnetLock
TotalIssuance